package com.example.demo.service.impl;

import com.example.demodao.IUserDao;
import com.example.demodao.entity.User;
import com.example.demo.service.IUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @program: yooli
 * @description: 用户实现类
 * @author: qiang.ye
 * @create: 2019-04-10
 **/
@Service
public class UserServiceImpl implements IUserService {


    @Autowired
    private IUserDao userDao;


    @Override
    public void saveUser(User user) {
        userDao.save(user);
    }

    @Override
    public List<User> findAll() {
        return userDao.findAll();
    }
}
